import requests
import json
import re

def getAttrsFromGitee():
    r = requests.get('https://gitee.com/w.y/wsmud_tuiyan_web/raw/master/wsmud_tuiyan_web/data/attrs.json')
    return r.json()

def getAttrs():
    raw_json = getAttrsFromGitee()
    attrs_re = {}
    for k in raw_json:
        attrs_re[k] = re.compile(raw_json[k])
    return attrs_re
